<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <input  placeholder="手机号"  id="tel" />
    <input    placeholder="密码"   id="pwd"/>
    <button    onclick="Login()">登录</button>
    <script   src="jquery.js"></script>
    <script>
        function Login(){
            $.post("https://java60.hfbdqn.cn/login"  ,{tel:tel.value,pwd:pwd.value},
            function(data){
                if(data){
                   
               localStorage.userInfo=       JSON.stringify(data);

                    location="chat.html";



                }else{
                    alert("登录失败");
                }






            }








            )







        }
    


        





    </script>




    
</body>
</html>